package com.googlecode.lohr.tools.parser;

import com.googlecode.lohr.parser.combinators.matcher.common.NameMatcher;

public class LohrIdentifierMatcher extends NameMatcher {
	
	boolean _acceptSpace;
	
	public LohrIdentifierMatcher(boolean acceptSpace) {
		_acceptSpace= acceptSpace;
	}
	
	@Override
	public boolean isNameChar(char c) {
		
		if (_acceptSpace && c == ' ')
			return true;
		return super.isNameChar(c);
	}
	
}
